package com.tarena.lbs.content.dao.repository.impl;

import com.tarena.lbs.content.dao.mapper.CategoryMapper;
import com.tarena.lbs.content.dao.repository.CategoryRepository;
import com.tarena.lbs.content.pojo.po.ArticleCategoryPO;
import com.tarena.lbs.content.pojo.query.ArticleCategoryQuery;
import com.tarena.lbs.content.pojo.vo.ArticleCategoryVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public class CategoryRepositoryImpl implements CategoryRepository {
    @Autowired
    private CategoryMapper categoryMapper;
    @Override
    public List<ArticleCategoryVO> selectCategory(ArticleCategoryQuery categoryQuery) {
        List<ArticleCategoryVO> list=categoryMapper.selectCategory(categoryQuery);
        return list;
    }

    @Override
    public void insert(ArticleCategoryPO po) {
        categoryMapper.insert(po);
    }
}
